{ config, pkgs, callPackage, ... }:

{
  imports =
    [ 
      ./hardware-configuration.nix
    ];

  nixpkgs.config.allowUnfree = true;

  boot.loader.grub.enable = true;
  boot.loader.grub.version = 2;
  boot.loader.grub.device = "/dev/sda"; 

  networking.hostName = "durian"; 
  networking.wireless.enable = true;  

  networking.useDHCP = false;
  networking.interfaces.enp0s25.useDHCP = true;
  networking.interfaces.wlp2s0.useDHCP = true;


   i18n.defaultLocale = "en_US.UTF-8";
   console = {
     font = "Lat2-Terminus16";
     keyMap = "us";
   };

  time.timeZone = "America/New_York";

  environment.systemPackages = with pkgs; [

    acpi 
    wget 
    visidata 
    btrfs-progs 
    git 
    mosh 
    rsync
    tig 
    tokei 
    irssi
    nnn 
    neofetch 
    tmux 
    fzf
    ripgrep
    tmux
    xclip
    vim
    coreutils
    emacs
    gnupg
    fd
    clang

  ];


  users.users.jgart.packages = with pkgs; [

    abcm2ps
    insomnia
    zathura
    evince
    grpcui
    stumpish
    flatpak
    pass
    pgcli
    sic
    imagemagick
    hexchat
    gnome3.gnome-terminal
    pscircle
    tiny
    kazam
    clojure
    gajim
    firefox
    chromium
    google-chrome
    qemu
    evince
    mu
    darcs
    haskellPackages.Agda
    lilypond-unstable
    libreoffice
    keepassxc
    python38Packages.pygments
    musescore
    pypi2nix
    httpie
    mpv
    st
    openscad
    zathura
    puredata
    python3
    ffmpeg
    inkscape
    sox
    superTux
    sbcl
    tor-browser-bundle-bin
    youtube-dl 
    racket-minimal
    wire-desktop 

  ];


  services.openssh.enable = false;

  virtualisation.docker.enable = true;


  services.printing.enable = true;

  sound.enable = true;
  hardware.pulseaudio.enable = true;

  services.xserver.enable = true;
  services.xserver.layout = "us";
  services.xserver.autorun = true;

  # Enable touchpad support.
  services.xserver.libinput.enable = true;

  services.xserver.displayManager.lightdm.enable = true;
  services.xserver.displayManager.lightdm.autoLogin.enable = true;
  services.xserver.displayManager.lightdm.autoLogin.user = "jgart";
 
  services.xserver.desktopManager.xfce.enable = true;


  users.users.jgart = {
    isNormalUser = true;
    uid = 1000;
    home = "/home/jgart";
    extraGroups = [ "wheel" "video" "audio" "disk" "networkmanager" ]; 
    useDefaultShell = true;
  };

  system.stateVersion = "20.03"; 

}

